package recursion;

/**
 * TOOD
 *
 * @author long
 * @date 2020-07-21 21:33
 */
public class printReverse {

    private static void printReverse(char[] str){
        helper(0,str);
    }

    private static void helper(int index,char[] str){
        if (str==null||index>=str.length){
            return;
        }
        helper(index+1,str);
        System.out.println(str[index]);
    }

    public static void main(String[] args) {
        char[] str={'A','B','C','d'};
        printReverse(str);
    }



}
